home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Belgian Amiga Club - ADF Collection
/
BS1 part 34.zip
/
BS1 part 34
/
Amigacall v3.51 prof.adf
/
SCRIPT
/
FuerProfis
< prev
next >
Wrap
Text File
|
1989-12-16
|
8KB
|
416 lines
#
# AUTO-LOGIN-SCRIPT JAT-BBS (C) 26.11.88 by J.Reisenweber
# (permission for distribution granted, if in connection
# with AmigaCall)
#
# (sorry for the english :-)
#
# Dieses Script wurde mir von Joerg Reisenweber zur Verfuegung
# gestellt. Es ist fuer diejenigen gedacht, die sich intensiv mit
# den Moeglichkeiten der Scripts auseinandersetzen und sich von
# Beispielen inspirieren lassen wollen.
#
# Dank an Joerg!
#
# Markus Schmidt
#
# Dieses Script ist fuer Anfaenger **NICHT** geeignet!!!
#
print ^[c
list "^[[2;10H^[[33;1mA - C a l l Autologon-script for BBS using"
print " HAYES-modem^[[m"
setn c,15
:scroll
print ^[[H
print ^[[L
dec c
compn !c! !with! 0
ifhigh goto scroll
print ^g^[[19;15H^[[1m^n)^o 26.11.88 J.Reisenweber^[[m
delay 3
# you might want to do this ->
# loadprefs prefs/autoload
#preset metas
setn br,0
seta mp,
seta dw,
setn mcc,0
:reask
# b m w c i x ? oder <cr>
# ask "@10,05; Baudrate Modemparams Doscmd Cmd-mailbox Info"
ask "@10,05;Do what? (b, m, d, c, i, x or ? for help)"
# case select-char
compa !lastline! !with! b
ifequ goto baudrate
compa !lastline! !with! m
ifequ goto modemparam
compa !lastline! !with! d
ifequ goto doswait
compa !lastline! !with! c
ifequ goto mbcmd
compa !lastline! !with! i
ifequ goto info
compa !lastline! !with! x
ifequ print ^j^j^m Hope 2 c u again!!
ifequ exit
compa !lastline! !with! g
ifequ goto waitmodem
#show help if ? or illegal cmd
goto help
# endcase
#
#sub baudrate
:baudrate
ask "@10,05;baudrate (<CR>=nochange)"
compa !lastline! !with!
ifequ goto reask
#refuse some false entries
setn x,!lastline!
compn !x! !with! 110
iflow yell
iflow goto baudrate
compn !x! !with! 19200
ifhigh yell
ifhigh goto baudrate
setn br,!x!
kill x
goto reask
#endsub
#sub modemparam
:modemparam
ask "@10,05;modemparameters (ommit starting AT)"
seta mp,!lastline!
goto reask
#endsub
#sub doswait
:doswait
ask "@10,05;DOS-command: (eg.wait until 4:00)"
seta dw,!lastline!
goto reask
#endsub
#sub mbcmd
:mbcmd
ask "BBS-command: (<CR>=end ';clr' cmds )"
compa !lastline! !with! ;clr
ifequ goto delmbcmd
compa !lastline! !with!
#exit
ifequ goto reask
inc mcc
seta mc!mcc!,!lastline!
goto mbcmd
#endsub
#subsub delmbcmd
:delmbcmd
compn !mcc! !with! 0
ifequ goto mbcmd
kill mc!mcc!
dec mcc
goto delmbcmd
#endsubsub
#sub help
:help
print ^[c^L^j
print "COMMANDS | PARAMETERS | NEXT REQUESTER
print "------------------+-----------------+----------------------------------"
print " | | "
print "Baudrate | 110-19200<CR> | new baudrate"
print " | <CR> | do not change baudrate"
print " | | "
print "Modem-parameters | <string> | any modem-command without 'AT', "
print " | | (e. g. 'M1 L2')"
print " | | "
print "Dos-command | <string> | any DOS-cmd, e.g. 'WAIT UNTIL 4:00."
print " | | executed before start dialing BBS"
print " | | "
print "Cmds for BBS | <string> | this string(s) will be sent to BBS"
print " | | login. You may enter multiple cmds,"
print " | | ending with a plain <CR> or clear "
print " | | all input by entering ';clr'"
print " | | "
print "Info | <no parameter> | shows current settings: (baudrate,"
print " | <no parameter> | modemparams, doscmd, bbs-cmds)"
print " | | "
print "eXit | | Obviously exit"
print "Go | | Go call a BBS"
print " | | "
print "? | | Obviously this"
print " | | text"
ask "@99,99;Hit RETURN to continue"
goto reask
#endsub
#sub info
:info
print baud:!br!
print modem:!mp!
print DOS:!dw!
print BBS-cmd(s)
setn c,1
:infoloop
compn !c! !with! !mcc!
#exit
ifhigh kill c
ifhigh kill x
ifhigh goto reask
print
seta x,!!mc!c!!!
print !c!:!x!
inc c
goto infoloop
#endsub
:waitmodem
dos !dw!
timeout 3
send AT^m
wait OK
ifnbrk goto resetmodem
send +++
wait OK
ifnbrk goto resetmodem
send ^Q^Q^Q
wait OK
ifnbrk goto resetmodem
goto waitmodem
:resetmodem
# you might want to do this ->
# loadprefs prefs/jat
compn !br! !with! 0
ifhigh baud !br!
delay 1
send atz^m
wait OK
ifnbrk goto initmodem
goto waitmodem
:initmodem
delay 1
send atx4 m0 b0 s7=50 s10=120 s11=50 s2=17 s12=80 !mp!^M
wait OK
:dialjat
setn tries,1
#passwort wird nicht im script gespeichert!!
ask "@10,05; Passwort JAT:"
seta pw,!lastline!
# you may want to ask for a number
# ask Enter number to dial
# seta number,!lastline!
# this version always dials 09120 9939
seta number,09120 9939
:redial
delay 1
timeout 100
dial !number!
wait ^j
wait ^j
exact 0
compa !lastline! !with! CONNECT 1200
ifequ goto firststart
exact 1
delay 1
compa !lastline! !with! BUSY
ifequ print ^[[2F
ifequ inc tries
ifequ goto redial
beep 5
:hangs
timeout 15
wait OK
ifnbrk goto redial
beep
goto hangs
:firststart
beep 3
seta ln,:AllOfJat/Login.!date!
clrcapt
capture 1
savecapt !ln!
timeout 40
:start
print ^mLOGIN AT !time!, after !tries! tries.
:restart
wait Username:
ifnbrk goto UserName
:NoLogon
timeout 5
SEND ^M
GOTO restart
:UserName
DELAY 1
timeout 5
SEND JOERG^M
wait Passwort:
ifnbrk goto PassWort
SEND ^M
GOTO restart
:PassWort
SEND !pw!^M
beep 3
timeout 60
wait Befehl: ^G
ifbrk goto start
:LoginOver
setn c,0
timeout 60
:cmdloop
inc c
compn !c! !with! !mcc!
ifhigh goto nocommand
seta x,!!mc!c!!!
send !x!^m
wait Befehl: ^G
ifbrk goto noreply
goto cmdloop
:noreply
yell 3
ask "@10,05;last cmd didn't return; continue/abort?"
compa !lastline! !with! c
ifequ goto cmdloop
print " ABORTED !!"
:nocommand
capture 0
savecapt !ln!
clrcapt
kill ln
seta ln,:AllOfJat/PM.!date!
clrcapt
CAPTURE 1
savecapt !ln!
send le *^M
timeout 300
:morePM
wait Befehl: ^G
ifnbrk goto EndCapture
compa !lastline! !with! NO CARRIER
ifequ capture 0
ifequ savecapt :AllOfJat/PM-ABORT.!date!
ifequ beep 20
ifequ exit
goto morePM
:EndCapture
CAPTURE 0
savecapt !ln!
clrcapt
kill ln
seta ln,:AllOfJat/ENTRIES.!date!
capture 1
savecapt !ln!
SEND brett !!^M
timeout 600
:moreEntries
wait Befehl: ^G
ifnbrk goto EndCapture2
compa !lastline! !with! NO CARRIER
ifequ capture 0
ifequ savecapt :AllOfJat/ENTRIES-ABORT.!date!
ifequ beep 20
ifequ exit
goto moreEntries
:EndCapture2
CAPTURE 0
savecapt !ln!
clrcapt
kill ln
seta ln, :AllOfJat/Files.!date!
clrcapt
capture 1
savecapt !ln!
SEND file inhalt neu^M
timeout 180
:moreFiles
wait Befehl: ^G
ifnbrk goto EndCapture3
compa !lastline! !with! NO CARRIER
ifequ capture 0
ifequ savecapt :AllOfJat/FILES-ABORT.!date!
ifequ beep 20
ifequ exit
goto moreFiles
:EndCapture3
CAPTURE 0
savecapt !ln!
clrcapt
kill ln
seta ln, :AllOfJat/Logout.!date!
capture 1
send e e^M
delay 2
send ^Q^Q^Q
delay 2
send ath^m
delay 1
capture 0
savecapt :AllOfJat/Logout.!date!
:jetzt-kommt-der-anruftracer
:waitfirstring
timeout 999999
wait RING
ifbrk goto waitfirstring
timeout 10
delay 1
print ^[[2F
kill tries
setn tries,1
:morerings
wait RING
delay 1
ifnbrk print ^[[2F
ifnbrk inc tries
ifnbrk goto morerings
print at !date! !time!, !tries! rings.
goto waitfirstring